package ink.yuanchu.picachoframework.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import ink.yuanchu.picachoframework.entity.Permissions;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 *
 * @author ziyuan
 * @Date: 2021/03/09/22:46
 * @Description:
 */
@Repository
public interface PermissionsMapper extends BaseMapper<Permissions> {

    /**
     * 根据roleId查询
     * @param roleId
     * @return
     */
    List<Permissions> findByRoleId(String roleId);

    /**
     * 根据permissionId去重查询
     * @return
     */
    List<Permissions> distinctPermissionId();
}
